package cn.icanci.ladybird.controller;

import cn.icanci.ladybird.service.user.UserBuyerTicketService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;

import javax.servlet.http.HttpServletRequest;

/**
 * @author: wirdeo
 * @date: Created in 2020/10/8 16:54
 * @classAction:
 */
@Controller
@RequestMapping("/api/v1/pri/user")
public class BuyerTicketController {
    @Autowired
    private UserBuyerTicketService userBuyerTicketService;
    @Autowired
    private UserBuyerTicketController userBuyerTicketController;

    @RequestMapping("/delete")
    public String getBuyerDelete(Model model, HttpServletRequest request, Long buyTicketId, Integer pageNum, Integer pageSize) {
        userBuyerTicketService.deleteById(buyTicketId);
        return userBuyerTicketController.userTicketList(model, request, pageNum, pageSize);
    }

}
